load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")

go_library(
    name = "go_default_library",
    srcs = [
        "authorizer.go",
        "definitions.go",
        "generated_mock_authorizer.go",
        "subresource.go",
    ],
    importpath = "kubevirt.io/kubevirt/pkg/virt-api/rest",
    visibility = ["//visibility:public"],
    deps = [
        "//pkg/controller:go_default_library",
        "//pkg/rest:go_default_library",
        "//pkg/util/status:go_default_library",
        "//pkg/virt-config:go_default_library",
        "//staging/src/kubevirt.io/client-go/api/v1:go_default_library",
        "//staging/src/kubevirt.io/client-go/apis/snapshot/v1alpha1:go_default_library",
        "//staging/src/kubevirt.io/client-go/kubecli:go_default_library",
        "//staging/src/kubevirt.io/client-go/log:go_default_library",
        "//vendor/github.com/emicklei/go-restful:go_default_library",
        "//vendor/github.com/golang/mock/gomock:go_default_library",
        "//vendor/k8s.io/api/authorization/v1beta1:go_default_library",
        "//vendor/k8s.io/api/core/v1:go_default_library",
        "//vendor/k8s.io/apimachinery/pkg/api/errors:go_default_library",
        "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library",
        "//vendor/k8s.io/apimachinery/pkg/fields:go_default_library",
        "//vendor/k8s.io/apimachinery/pkg/labels:go_default_library",
        "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library",
        "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library",
        "//vendor/k8s.io/apimachinery/pkg/types:go_default_library",
        "//vendor/k8s.io/apimachinery/pkg/util/json:go_default_library",
        "//vendor/k8s.io/apimachinery/pkg/util/yaml:go_default_library",
        "//vendor/k8s.io/client-go/kubernetes/typed/authorization/v1beta1:go_default_library",
        "//vendor/k8s.io/client-go/rest:go_default_library",
    ],
)

go_test(
    name = "go_default_test",
    srcs = [
        "authorizer_test.go",
        "rest_suite_test.go",
        "subresource_test.go",
    ],
    embed = [":go_default_library"],
    deps = [
        "//pkg/testutils:go_default_library",
        "//pkg/util/status:go_default_library",
        "//pkg/virt-config:go_default_library",
        "//staging/src/kubevirt.io/client-go/api/v1:go_default_library",
        "//staging/src/kubevirt.io/client-go/kubecli:go_default_library",
        "//staging/src/kubevirt.io/client-go/log:go_default_library",
        "//vendor/github.com/emicklei/go-restful:go_default_library",
        "//vendor/github.com/onsi/ginkgo:go_default_library",
        "//vendor/github.com/onsi/ginkgo/extensions/table:go_default_library",
        "//vendor/github.com/onsi/gomega:go_default_library",
        "//vendor/github.com/onsi/gomega/ghttp:go_default_library",
        "//vendor/k8s.io/api/core/v1:go_default_library",
        "//vendor/k8s.io/apimachinery/pkg/api/errors:go_default_library",
        "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library",
        "//vendor/k8s.io/apimachinery/pkg/util/uuid:go_default_library",
        "//vendor/k8s.io/client-go/kubernetes/typed/authorization/v1beta1:go_default_library",
        "//vendor/k8s.io/client-go/tools/clientcmd:go_default_library",
    ],
)
